package com.sky.service.impl;

import com.sky.domain.Grade;
import com.sky.mapper.GradeMapper;
import com.sky.service.GradeService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * @author 尹稳健~
 * @version 1.0
 */
@Service
public class GradeServiceImpl implements GradeService {

    @Autowired
    private GradeMapper gradeMapper;

    public List<Grade> selectAll() {
        return gradeMapper.selectAll();
    }

    public List<Grade> getGradeList(Grade grade) {
        return gradeMapper.getGradeList(grade);
    }

    public Grade findByName(String name) {
        return gradeMapper.findByName(name);
    }

    public void addGrade(Grade grade) {
        gradeMapper.addGrade(grade);
    }

    public void editGrade(Grade grade) {
        gradeMapper.editGrade(grade);
    }

    public void deleteGrade(Integer[] ids) {
        gradeMapper.deleteGrade(ids);
    }
}
